<script>
	function shallowCopy(obj) {
		let res = {...obj};
		return res;
	}

	let obj = {
		a: 1,
		b: {
			a: 22,
		},
		c: /^\d{11}$/,
		d: new Date(),
		e: function(){console.log('a')}
	}
	let res = shallowCopy(obj);
	console.log(res);
</script>